package org.example.dao.bank;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.example.entity.bank.BankQuestionResultEntity;

/**
 * @author puqingwen
 * @since 2024-03-12
 */
@Mapper
public interface BankQuestionResultDao extends BaseMapper<BankQuestionResultEntity> {

    @Select("SELECT IFNULL(MAX(batch_num),0)+1 as val FROM tb_bank_test_question_result where `user_id`=#{arg0}")
    int getMaxBatchByUser(Integer num);
}
